

function get (url,params,callback){
    const xhr = new XMLHttpRequest();
    xhr.open('get',url);
     
    xhr.onreadystatechange =()=>{
        if(xhr.readyState ===4){
            if(xhr.status ===200){
                let res = JSON.parse(xhr.responseText);
                callback(res)
            }else{
                console.log(xhr.status);
            }
        }
    }
    xhr.send(params)
    
}